package club.zhilin.guli.service.edu.service;

import club.zhilin.guli.common.base.result.CommonResult;
import club.zhilin.guli.service.edu.domain.CourseCollect;
import club.zhilin.guli.service.edu.domain.vo.CourseCollectVO;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * <p>
 * 课程收藏 服务类
 * </p>
 *
 * @author zhilin
 * @since 2022-01-11 15:29:01
 */
public interface ICourseCollectService extends IService<CourseCollect> {

    /**
     * 通过courseId和会员id进行收藏
     *
     * @param courseId 课程id
     * @param id       会员id
     * @return commonResult
     * @see CommonResult
     */
    CommonResult<String> collect(String courseId, String id);

    /**
     * 查询收藏列表
     *
     * @param id 会员id
     * @return commonResult
     * @see CommonResult
     */
    CommonResult<List<CourseCollectVO>> selectList(String id);

    /**
     * 删除收藏
     *
     * @param courseId 课程id
     * @param id       会员id
     * @return commonResult
     * @see CommonResult
     */
    CommonResult<String> delCollect(String courseId, String id);
}
